package com.niiwoo.civet.trade.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * Created by bincun on 2017/11/18.
 */
@Getter
@AllArgsConstructor
public enum CreditorUserTypeEnum {
    INVESTOR((byte)0,"投资人"),
    GUARANTEE((byte)1,"债权人");
    private Byte value;
    private String desc;

    public static CreditorUserTypeEnum enumOf(byte value) {
        for (CreditorUserTypeEnum typeEnum : values()) {
            if (typeEnum.value == value) {
                return typeEnum;
            }
        }
        return null;
    }

}
